﻿<%@ Page Title="Fare Importing" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="FareImporting.aspx.cs" Inherits="IFD2.FareImporting" %>
<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
    <form id="form1" runat="server" role="form" class="form-inline" defaultbutton="lbtnQuery">
    <div class="container-fluid body-content" style="width:100%;">

    <div class="row">
        <div class="col-sm-2 well well-sm">
            <h5><asp:Literal ID="litTitle" runat="server" meta:resourcekey="tipPageTitle"></asp:Literal></h5>
            <br class="hidden-xs"/>
            <asp:LinkButton ID="lbtnQuery" runat="server" CssClass="form-control input-sm btn-primary text-center" Width="100%" ToolTip="" meta:resourcekey="tipQuery" OnClick="lbtnQuery_Click"> <span class="glyphicon glyphicon-search" style="font-size:large;"></span></asp:LinkButton>
            <p></p><%--没有此行(或&nbsp;)，上面的按钮在手机模式(xs)下，只有上半部可以点击！--%>
        </div>

        <div class="col-sm-10 well well-sm">
            <div class="panel">
                <div class="panel-heading btn-primary">
                    <h6 class="panel-title" id="section-2"><asp:Literal ID="Literal1" runat="server" meta:resourcekey="AuthorizedImportingAirlines"></asp:Literal></h6>
                </div>
                <div class="panel-body">
                    <div class="table-responsive">
                        <asp:GridView ID="GridView1" runat="server" CellPadding="4" ForeColor="#333333" style="min-width:200px;" class="table-hover"
                            GridLines="None" AutoGenerateColumns="False" DataSourceID="sqlInportList">
                            <AlternatingRowStyle BackColor="White" />
                            <Columns>
                                <asp:TemplateField>
                                    <ItemTemplate>
                                    <input name="KEY" type="radio" value='<%# Eval("exporter") %>' />
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:BoundField DataField="exporter" HeaderText="Airline" SortExpression="exporter"  meta:resourcekey="exporter" />
                            </Columns>
                            <EditRowStyle BackColor="#2461BF" />
                            <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                            <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                            <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                            <RowStyle BackColor="#EFF3FB" />
                            <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                            <SortedAscendingCellStyle BackColor="#F5F7FB" />
                            <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                            <SortedDescendingCellStyle BackColor="#E9EBEF" />
                            <SortedDescendingHeaderStyle BackColor="#4870BE" />
                        </asp:GridView>
                    </div>
                    <asp:Button ID="btnDelete" runat="server" Text="Delete" onclick="btnDelete_Click"  meta:resourcekey="Delete" CssClass="btn btn-default btn-sm" />
                    <br />
                    <asp:Label ID="lblError" runat="server" CssClass="ifdMessage"></asp:Label>

                    <div class="well well-sm">
                        <asp:ListBox ID="lstAirlines" runat="server" DataSourceID="SqlDataSource1" 
                            DataTextField="code" DataValueField="code" Height="121px" Width="87px">
                        </asp:ListBox>
                        <asp:Button ID="btnAdd" runat="server" Text=" Add " onclick="btnAdd_Click"  meta:resourcekey="Add" CssClass="btn btn-default btn-sm" />
                    </div>
                </div>
                <asp:SqlDataSource ID="SqlDataSource1" runat="server"  DataSourceMode="DataReader" ConnectionString="<%$ ConnectionStrings:IFD_DB %>" 
                    SelectCommand="bll_airline_get_codes" SelectCommandType="StoredProcedure">
                </asp:SqlDataSource>
                <asp:SqlDataSource ID="sqlInportList" runat="server"  DataSourceMode="DataReader" ConnectionString="<%$ ConnectionStrings:IFD_DB %>" 
                    SelectCommand="bll_fare_get_authorized_import_airlines" SelectCommandType="StoredProcedure">
                    <SelectParameters>
                        <asp:SessionParameter Name="airline" SessionField="AIRLINE" Type="String" />
                    </SelectParameters>
                </asp:SqlDataSource>
            </div>
        </div>
    </div>

    </div>
    </form>
</asp:Content>
